<link type="text/css" href="/admins/js/jquery/css/ui-lightness/jquery-ui-1.8.20.custom.css" rel="stylesheet" >
<script type="text/javascript" src="/admins/js/My97DatePicker/WdatePicker.js"></script>
<link href="/js/boxy/css/boxy.css" media="screen" rel="stylesheet" type="text/css" >
<link href="/admins/css/yundan.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="/js/boxy/js/jquery.boxy.js"></script>
<script type="text/javascript" src="/admins/js/My97DatePicker/WdatePicker.js"></script>
<link type="text/css" href="/admins/js/jquery/css/ui-lightness/jquery-ui-1.8.20.custom.css" rel="stylesheet" />
<div class="admin_nrtop">
      <div class="ad_search">
            <form action=""  method="get" style="margin:0px" id="form1">
                  <input type="hidden" id="pagesize" name="pagesize" value=""/>
                  <input type="hidden" id="starttime" name="starttime" value="<?php echo $this->starttime?$this->starttime:"";?>"/>
                  <input type="hidden" id="endtime" name="endtime" value="<?php echo $this->endtime?$this->endtime:"";?>" />
                  <div class="timebox">
                        <div class="ad_time" style="width:320px;">
                            <div class="timefw">
                                <div class="time">
                                    <!--点击后悬停样式为：<div class="timeselect t_on">-->
                                    <div class="timeselect"  id="stime">
                                        <span id="stimeval"><?php echo $this->starttime?$this->starttime:date("Y-m-d",mktime(0,0,0,date("m"),date("d")-30,date("Y")));?></span><i></i>
                                    </div>
                                    <div class="timeslelctbox">
                                        <!---时间插件放此DIV-->
                                    </div>
                                </div>
                                <div class="timezhi">
                                    <span>至</span>
                                </div>
                                <div class="time" >
                                    <div class="timeselect" id="etime">
                                        <span id="etimeval"><?php echo $this->endtime?$this->endtime:date("Y-m-d");?></span><i></i>
                                    </div>
                                    <div class="timeslelctbox">
                                        <!---时间插件放此DIV-->
                                    </div>
                                </div>
                            </div>
                        </div>
                        <div class="timeok">
                            <a href="javascript:$('#form1').submit();">确定</a>
                        </div>
                    </div>
            </form>
            <h3 style="font-size:22px;font-weight:normal;">用户支付记录</h3>
      </div>
</div>
<div  class="biaoge">
      <div class="biaotbody">
            <table >
                  <tr>
                        <th class="li10" style="text-align:center">
                              仓库号
                        </th>
                        <th class="li10" >
                              时间
                        </th>
                        <th class="li10" >
                              交易号
                        </th>
                        <th class="li8" >
                              金额
                        </th>
                        <th class="li10" >
                              美元
                        </th>
                        <th class="li8" >
                              汇率
                        </th>
                        <th class="li8" >
                              支付类型
                        </th>
                        <th class="li8" >
                              类型
                        </th>
                  </tr>
            </table>
      </div>
      <div class="table" style='margin-top:0px;'>
             <table>
<?php
if ($this->resultlist) {
      foreach ($this->resultlist as $key => $Item) {
            ?>
                        <tr>
                              <td class="li10" align="center"><?php echo Application_Model_User::getByUserId($Item->accountId)->storeno?></td>
                              <td class="li10" >
                                    <div class="yubm">
                                    <?php echo $Item->dateCreated ?>
                                          </a></div>
                              </td>
                              <td class="li10" >
                                    <?php echo $Item->txnId?>
                              </td>
                              <td class="li8" ><?php echo $Item->money ?></td>
                              <td class="li10" ><?php echo $Item->usmoney ?></td>
                              <td class="li8" ><?php echo $Item->rate ?></td>
                              <td class="li8" >
                                    <?php echo $Item->payname;?>
                              </td>
                              <td class="li8" >
                                    <?php echo Application_Model_PayBill::getTypeName($Item->type)?>
                              </td>
                        </tr>
                  
            <?php
                  }
            } else {
                  echo '<div class="tablebox"></div>';
            }
            ?>
                        </table>
      </div>
</div>
<div class="toolbar">
<?php echo $this->partial('paging.phtml', array("pages" => $this->resultAll, "pamas" => "quick=" . $this->status . "&starttime=$this->starttime&endtime=$this->endtime")); ?>
</div>
<table>    
<tfoot>
      <tr>
          <td colspan="2">　
              &nbsp;&nbsp;&nbsp;<button class="button" id="csv-button" style="background-color: #1668A4;width: 80px;height: 30px;color: white;font-size: 14px;border-radius:8px;">导出csv</button>
          </td></tr>
</tfoot>    
</table>
<script type="text/javascript">
      $(document).ready(function() {
            $(".timezdy").click(function() {
                  $(".timezdy .timeselect2").attr("class", "timeselect2 timeon");
                  $(".timeslelct_xl").show();
            });
            $(".timezdy").mouseleave(function() {
                  $(".timeselect2").attr("class", "timeselect2");
                  $(".timeslelct_xl").hide();
            });
            $("#stime").click(function() {
                  $(this).attr("class", "timeselect t_on");
                  WdatePicker({el: 'stimeval', vel: 'starttime', onpicked: function() {
                              $("#stime,#etime").attr("class", "timeselect");
                        }});
            });
            $("#etime").click(function() {
                  $(this).attr("class", "timeselect t_on");
                  WdatePicker({el: 'etimeval', vel: 'endtime', onpicked: function() {
                              $("#stime,#etime").attr("class", "timeselect");
                        }});
            });
            $('#csv-button').click(function(){
                  if(confirm("确定要导出！")){
                      $("#form1").attr("action","/admini/managedata/dumplog");
                      $('#pagesize').val('1000');
                      $('#form1').submit();
                      $('#pagesize').val('10');
                      $('#export').val("");
                  }
              });
      });
</script>